<template>
    <div>
        <van-card v-for="item in info" :key="item.proNo" @click="goDetail(item.productId)">
                <template #title>
                    <div class="title"><p>{{item.proTitle}}</p></div>
                </template>
                <template #thumb>
                    <img :src="item.proPicUrl" alt="" width="146">
                </template>
                <template #desc>
                    <div>
                        <p class="place"><em class="iconfont icon-mudedi"></em><span>{{item.country}}</span></p>
                        <p>
                            <span class="spans iconfont icon-shijian">{{item.routingDat}}天{{item.routingNigth}}晚</span>
                            <span class="spans iconfont icon-qian">{{item.amount}}元起</span>
                        </p>
                    </div>
                </template>
        </van-card>
    </div>
</template>

<script>
import Vue from 'vue';
import {Card,Tag} from 'vant';

Vue.use(Card);
Vue.use(Tag);


import '@/assets/iconfont1/iconfont.css'
export default {
    data () {
        return {
            info:[]
        };
    },

    components: {},

    computed: {},

    created(){
        // let url='/hehe/total'
        // this.$http.post(url)
        // .then(res=>{
        //     this.info=res
        // })

        let json1={
            "desc": false,
            "orderBy": "top",
            "pageNow": 1,
            "pageSize": 20,
            "seller_user_id": "4bc4027c645343f09a964b5c2e9f875b"
        }
        this.$http.post('http://www.51houniao.com/product/product/getProductRecommendUser',json1)
        .then(res=>{
            this.info=res
        })
    },

    mounted() {},

    methods: {
        goDetail(id){
            this.$router.push("/detail/"+id)
        }
    }
}

</script>
<style scoped>
.spans{
    display: inline-block;
    margin-right:10px;
    font-size:14px;
}
.van-card__thumb img{
    border-radius: 0;
    margin-left:-10px;
}
.van-card__content{
    margin-left:50px;
    line-height:10px;
}
.title{
    font-size:15px;
}
.place{
    min-width:20px;
    padding:5px;
    background: #ccc;
    border-radius: 10px;
    margin:0px;
}
</style>